package org.jie.guider.framework.hikari.spi;

import java.util.Iterator;
import java.util.ServiceLoader;

/**
 * @author LiJie
 */
public class SpiUtil {

    public static void main(String[] args) {
        ServiceLoader<Fruit> loader = ServiceLoader.load(Fruit.class);
        Iterator<Fruit> fruits = loader.iterator();
        while (fruits.hasNext()) {
            System.out.println(fruits.next().name());
        }
    }
}
